'use strict';

/** @type {import('sequelize-cli').Migration} */
module.exports = {
  async up (queryInterface, Sequelize) {
    
      await queryInterface.bulkInsert('Categories', [
        { name: '前端开发', range: 1, createdAt: new Date(), updatedAt: new Date() },
        { name: '后端开发', range: 2, createdAt: new Date(), updatedAt: new Date() },
        { name: '全栈开发', range: 3, createdAt: new Date(), updatedAt: new Date() },
        { name: '移动开发', range: 4, createdAt: new Date(), updatedAt: new Date() },
        { name: '人工智能', range: 5, createdAt: new Date(), updatedAt: new Date() },
        { name: '数据分析', range: 6, createdAt: new Date(), updatedAt: new Date() },
        { name: '云计算', range: 7, createdAt: new Date(), updatedAt: new Date() },
        { name: '网络安全', range: 8, createdAt: new Date(), updatedAt: new Date() },
        { name: '数据库', range: 9, createdAt: new Date(), updatedAt: new Date() },
        { name: '运维', range: 10, createdAt: new Date(), updatedAt: new Date() },
        { name: '其他', range: 11, createdAt: new Date(), updatedAt: new Date() },
      ], {});
  },

  async down (queryInterface, Sequelize) {
    await queryInterface.bulkDelete('Categories', null, {});
  }
};
